package com.envcloud.p1.controller;

import com.envcloud.dto.UserDto;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;

/**
 * File Name             :  UserController
 * Author                :  luhao
 * Create Date           :  2017/8/14
 * Description           :
 * Reviewed By           :
 * Reviewed On           :
 * Version History       :
 * Modified By           :
 * Modified Date         :
 * Comments              :
 * CopyRight             : COPYRIGHT(c) www.envcloud.com.cn (环境云) All Rights Reserved
 * *******************************************************************************************
 */
@RestController
public class UserController {

    @PostMapping("/sayHello")
    public String sayHallo(@RequestBody UserDto userDto) {
        return userDto.getUsername() + ", Welcome to Spring Cloud!";
    }

}
